﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage/Administrator.Master" AutoEventWireup="true" CodeBehind="SurveyCatalog.aspx.cs" Inherits="ProjectSemIII.Administrator.Survey.SurveyCatalog" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    Survey Catalog
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div class="widget">
        <div class="whead">
            <h6>Create Survey Catalog</h6>
            <div class="clear"></div>
        </div>
        <div class="formRow">
            <div class="grid3">
                <label>Survey Catalog Name<span class="req">*</span>:</label>
                <asp:TextBox ID="SurveyCatalogName" runat="server" Width="50%"></asp:TextBox>
                <asp:Button CssClass="buttonS bLightBlue" OnClick="submitCreateCatalog_Click" runat="server" ID="submitCreateCatalog" Text="Create New Catalog" />
                <asp:Label ID="status" runat="server" Text=""></asp:Label>
            </div>
            <div class="clear"></div>
        </div>
    </div>

    <div class="divider"><span></span></div>

    <div class="widget">
        <div class="whead">
            <h6>Edit Survey Catalog Name</h6>
            <div class="clear"></div>
        </div>
        <div class="formRow">
            <div class="grid3">
                <label>Survey Catalog Name<span class="req">*</span>:</label>
                <asp:TextBox ID="txtCatalogName" Enabled="false" runat="server" Width="50%"></asp:TextBox>
                <asp:HiddenField ID="hdIDSurveyCatalog" runat="server" />
                <asp:Button CssClass="buttonS bLightBlue" OnClick="btEditCatalogName_Click" runat="server" ID="btEditCatalogName" Text="Edit Catalog Name" />
                <asp:Label ID="lbStatus" runat="server" Text=""></asp:Label>
            </div>
            <div class="clear"></div>
        </div>
        <div class="pagination">
            <asp:Repeater ID="totalPage" runat="server">
                <HeaderTemplate>
                    <ul class="pages">
                        <li class="prev">
                            <asp:LinkButton runat="server" ID="btPrev" OnClick="btPrev_Click">&lt;</asp:LinkButton></li>
                </HeaderTemplate>
                <ItemTemplate>
                    <li>
                        <asp:LinkButton runat="server" ID="PageNumber" OnClick="PageNumber_Click" Text='<%# Container.DataItem.ToString() %>'></asp:LinkButton></li>
                </ItemTemplate>
                <FooterTemplate>
                    <li class="next">
                        <asp:LinkButton runat="server" ID="btNext" OnClick="btPrev_Click">&gt;</asp:LinkButton></li>
                    </ul>
                </FooterTemplate>
            </asp:Repeater>
        </div>
        <div class="widget check">
            <div class="whead">
                <h6>All Survey Catalog</h6>
                <div class="clear"></div>
            </div>
            <asp:Repeater ID="allCatalog" runat="server" OnItemCommand="allCatalog_ItemCommand">
                <HeaderTemplate>
                    <table cellpadding="0" cellspacing="0" width="100%" class="tDefault checkAll tMedia" id="checkAll">
                        <thead>
                            <tr>
                                <td width="50">ID</td>
                                <td class="sortCol">
                                    <div>Catalog Name<span></span></div>
                                </td>
                                <td width="100">Actions</td>
                            </tr>
                        </thead>
                        <tbody>
                </HeaderTemplate>
                <ItemTemplate>
                    <tr>
                        <td><%# Eval("CatalogID") %></td>
                        <td class="textL"><%# Eval("CatalogName") %></td>
                        <td class="tableActs">
                            <asp:ImageButton CommandName="Edit" CommandArgument='<%# Eval("CatalogID") %>' ImageUrl="~/App_Themes/Administrator/images/icons/update.png" runat="server" CssClass="tablectrl_small bDefault tipS" title="Edit"></asp:ImageButton>
                            <asp:ImageButton CommandName="Delete" OnClientClick="return confirm('Are you sure that you want to delete this survey catalog?');" CommandArgument='<%# Eval("CatalogID") %>' ImageUrl="~/App_Themes/Administrator/images/icons/delete.png" runat="server" CssClass="tablectrl_small bDefault tipS" title="Remove"></asp:ImageButton>
                        </td>
                    </tr>
                </ItemTemplate>
                <FooterTemplate>
                    </tbody>
                </table>
                </FooterTemplate>
            </asp:Repeater>
        </div>
    </div>

    <div class="divider"><span></span></div>

</asp:Content>
